package com.zhuifeng.orders.factory;

import com.zhuifeng.common.core.domain.R;
import com.zhuifeng.orders.remote.RemoteOrdersService;
import com.zhuifeng.product.domain.ProductSku;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.cloud.openfeign.FallbackFactory;
import org.springframework.stereotype.Component;



/**
 * 订单服务
 *
 * @author zhuifeng
 */
@Component
public class RemoteOrdersFallbackFactory implements FallbackFactory<RemoteOrdersService>
{
    private static final Logger log = LoggerFactory.getLogger(com.zhuifeng.orders.factory.RemoteOrdersFallbackFactory.class);


    @Override
    public RemoteOrdersService create(Throwable cause) {
        return new RemoteOrdersService() {
            @Override
            public R updateProductSkuStock(ProductSku productSku) {
                return null;
            }
        };
    }
}
